//
//  VBUserAccountModel.swift
//  VBo
//
//  Created by 赵世得 on 2016/10/28.
//  Copyright © 2016年 Zh. All rights reserved.
//

import UIKit
class VBUserAccountModel: NSObject, NSCoding {
    var access_token: String?
    var expires_in:TimeInterval = 0{
        didSet{
            expires_Date = Date().addingTimeInterval(expires_in)
        }
    }
    var uid: String?
    var avatar_large: String?
    var screen_name: String?
    var expires_Date: Date?
    override init() {
        super.init()
    }
    func encode(with aCoder: NSCoder) {
        self.yy_modelEncode(with: aCoder)
    }
    required init?(coder aDecoder: NSCoder) {
        super.init()
        self.yy_modelInit(with: aDecoder)
    }
    
    
    
    
    override var description: String{
        let keys = ["access_token", "expires_Date", "uid", "avatar_large", "screen_name"]
        
        return dictionaryWithValues(forKeys: keys).description
    }
}
